public class nasd {
    public void showInfo(){
        System.out.println("renyuanxinxi:"+id+","+name);
    }
}


public class Student extends Person{
    @Override
    public void showInfo(){
        super.showInfo();
        System.out.println("shenfen:xuesheng,chengji:"+score+"fen");
    }
}
public class Teacher extends Person{
    private String title;

    public Teacher(String id,String name,String title){
        super(id,name);
        this.title = title;
    }
    @Override
    public void showInfo(){
        super.showInfo();
        System.out.println("shenfen:jiaoshi,zhicheng:"+title);
    }
}
public class TestInheritance2{
    public static void main(String[] args){
        Person p1 = new Student("4545146","USADHI",56);
        Person p2 = new Teacher("514565","saddsa","sadsadw");
        p1.showInfo();
        System.out.println("-----");
        p2.showInfo();
    }
}